<?php 

include '../function.php';

$db = new PDO("mysql:host=127.0.0.1;dbname=school;charset=utf8","root","");

// $db->query("set names utf8");

$sql = "insert into stu (namsdfsdfsdfsdfe,age) values('小小bbbb','20')";
$sql = "select * from stu";

$res = $db->query($sql);

// if(!$res){
// 	var_dump($db->errorInfo());
// }

var_dump($res->fetchAll(PDO::FETCH_ASSOC));



















 ?>